

<script src="__STATIC__/js/jquery-1.10.2.min.js"></script>
<script src="__STATIC__/js/echarts.min.js"></script>
<include file="public@layuihead"/>


<div class="layui-fluid">
	<div class="layui-row layui-col-space15">
		<div class="layui-col-md11">
			<div class="layui-row layui-col-space15">

				<div class="layui-col-md10">
					<div class="layui-card">
						<div class="layui-card-header">数据统计</div>
						<div class="layui-card-body">

							<div class="layui-carousel layadmin-carousel layadmin-backlog">
								<div carousel-item>
									<ul class="layui-row layui-col-space10">
										<li class="layui-col-xs6">
											<a  class="layadmin-backlog-body">
												<h3>用户数</h3>
												<p><cite>{$users}</cite></p>
											</a>
										</li>
										<li class="layui-col-xs6">
											<a  class="layadmin-backlog-body">
												<h3>总项目</h3>
												<p><cite>{$all}</cite></p>
											</a>
										</li>
										<li class="layui-col-xs6">
											<a class="layadmin-backlog-body">
												<h3>总报单</h3>
												<p><cite>{$count}</cite></p>
											</a>
										</li>

									</ul>

								</div>
							</div>
						</div>
					</div>
				</div>


				<div class="layui-col-md10">
					<div class="layui-card">
						<div class="layui-card-header">数据概览</div>
						<div class="layui-card-body">


							<div style="margin-left: 20px">

								<div id="main" style="width: 1000px;height:500px;"></div>

							</div>

							<script src="__STATIC__/js/admin.js"></script>
							<php>
								$lang_set=defined('LANG_SET')?LANG_SET:'';
								$thinkcmf_version=cmf_version();
							</php>

							<hook name="admin_before_body_end"/>

							<script>



								var chartDom = document.getElementById('main');
								var myChart = echarts.init(chartDom);
								var option;
								var url="{:url('useradd')}";


								$.ajax({
									url:url,
									data:'',
									type:'post',
									dataType:'json',
									success:function (ret){


										option = {
											xAxis: {
												type: 'category',
												data: ['7', '6', '5', '4', '3', '2', '1']
											},
											yAxis: {
												type: 'value'
											},
											title: {
												text: '近7日用户增'
											},
											series: [
												{
													data: ret,
													type: 'line',
													smooth: true
												}
											]
										};

										option && myChart.setOption(option);
									}
								})



							</script>

						</div>
					</div>



				</div>
			</div>
		</div>


	</div>
</div>

<script src="/static/layuiadmin/layui/layui.js?t=1"></script>
<script>
	layui.config({
		base: '/static/layuiadmin/' //静态资源所在路径
	}).extend({
		index: 'lib/index' //主入口模块
	}).use(['index', 'console']);
</script>
</body>
</html>

